import React from 'react';
import {
    MenuOutlined,
    SettingOutlined,
    FileExclamationOutlined,
    ShopOutlined,
    PlusSquareOutlined,
    GroupOutlined,
    PieChartOutlined
} from '@ant-design/icons';

/**
 * 通用菜单icon配置，可自定义icon     https://ant.design/components/icon-cn/
 * @param icon
 * 注意项：自定义的icon由于大小不一,因此需要根据实际进行样式调整。svg引入时采用统一默认样式
 *         fontSize  调整图标大小
 *         color  调整图标颜色
 *         marginLeft  marginRight  调整左右间距
 *         verticalAlign  调整上下间距
 *
 */
export const getIcon = (icon = "menu") => {
    switch (icon) {
        case "menu" : return <MenuOutlined />;
        case "system" : return <SettingOutlined />;
        case "log" : return <FileExclamationOutlined />;
        case "shenqingdan": return <PlusSquareOutlined />;
        case "service": return <GroupOutlined />;
        case "activity": return <ShopOutlined />;
        case "reports": return <PieChartOutlined />;
        default: return <MenuOutlined />;
    }
};